class CreatePosts < ActiveRecord::Migration
  def change
    create_table :posts do |t|
      t.string :title
      t.text :content
      t.string :pic
      t.string :video
      t.integer :cateid, :default => 0, :null => false
      t.string :paras
      t.integer :source, :default => 0, :null => false
      t.string :tag
      t.integer :hit, :default => 0, :null => false
      t.string :url
      t.string :userid
      t.string :userip
      t.integer :sortid, :default => 0, :null => false
      t.datetime :postdate, :null => false

      t.timestamps
    end
  end
end
